<template>
    <div id="app">
       <child :msg="msg" @change="test"></child>
    </div>
</template>

<script>
import child from './components/child'
export default {
    components:{
        child
    },
    data(){
        return {
            msg:'您好'
        }
    },
    created(){
        this.$bus.$on('test',() => {
            this.msg = '孙子改的';
        })
    },
    methods:{
        test(){
            this.msg = 'hello-->您好';
        }
    }
}
</script>

<style>
@import "./assets/common.css";

</style>
